package com.hsurosy.hsuchain.nft.api.collection.request;

import com.hsurosy.hsuchain.nft.api.collection.constant.CollectionEvent;
import jakarta.validation.constraints.NotNull;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 基础藏品请求类
 *
 * @Author Hsu琛君珩
 * @Date 2024-10-04 14:44
 * @Description
 * @Version: v1.0.0
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class BaseCollectionRequest extends BaseRequest {

    /**
     * 幂等号
     * 用于确保请求的幂等性
     */
    @NotNull(message = "identifier is not null")
    private String identifier;

    /**
     * 藏品ID
     */
    private Long collectionId;

    /**
     * 获取事件类型
     *
     * @return 藏品事件类型
     */
    public abstract CollectionEvent getEventType();
}
